package com.ali.common;

import java.time.Duration;
import java.time.temporal.Temporal;

public class DurationUtil {
    /**
     * 获取相差秒
     */
    public static long getBetweenSecond(Temporal startInclusive, Temporal endExclusive) {
        return Duration.between(startInclusive, endExclusive).getSeconds();
    }
}